fix: align Docker Go version with go.mod and optimize logger#596
Open
hobostay wants to merge 1 commit intosipeed:mainfrom
Open
fix: align Docker Go version with go.mod and optimize logger#596hobostay wants to merge 1 commit intosipeed:mainfrom
hobostay wants to merge 1 commit intosipeed:mainfrom
Conversation
- Update Dockerfile to use golang:1.25-alpine to match go.mod (go 1.25.7) - Optimize logger by avoiding string concatenation in file writes - Add explicit empty string assignment for fieldStr when no fields These changes improve build consistency and reduce memory allocations in the hot logging path, which is important for the project's goal of running on resource-constrained devices (<10MB RAM). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Collaborator
|
Can you please update this PR to use the default PR template? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR fixes build consistency issues and optimizes the logger for better memory efficiency.
Changes
Dockerfile
golang:1.26.0-alpinetogolang:1.25-alpinego.modwhich specifiesgo 1.25.7pkg/logger/logger.go
append(jsonData, '\n')instead ofstring(jsonData) + "\n"fieldStrwhen no fields are presentBenefits
Testing
Co-Authored-By: Claude Sonnet 4.6 noreply@anthropic.com